<template>
  <div class="toast" v-show="isShowToast">
    <span>{{showText}}</span>
  </div>
</template>

<script>
export default {
  name: 'Toast',
  data () {
    return {
      isShowToast: false,
      showText: ''
    }
  },
  methods: {
    showToast (a) {
      this.showText = a
      this.isShowToast = true
      setTimeout(() => {
        this.isShowToast = false
      }, 1000)
    }
  }
}
</script>
